package com.boyunv.decorator.example02;/*
 *@description
 *
 *@author boyunv
 *@create 2023/7/16 9:07
 *@version 1.0
 */

public class Client {
    public static void main(String[] args) {
        String info="name:YangFan,age:30";

       /* DataLoader loader=new BaseFileLoader("demo.txt");
        loader.write(info);
        String read = loader.read();
        System.out.println(read);*/
        DataLoaderDecorator encryptionDecorator = new EncryptionDecorator(new BaseFileLoader("demoo02.txt"));
        //encryptionDecorator.write(info);

        String enRead = encryptionDecorator.read();
        System.out.println(enRead);


    }
}
